﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class Index : System.Web.UI.Page
{
    private static Maticsoft.BLL.PlateOfTheMsg plateOfTheMsgBLL = new Maticsoft.BLL.PlateOfTheMsg();
    static IList<Maticsoft.Model.PlateOfTheMsg> listPlate = new List<Maticsoft.Model.PlateOfTheMsg>();
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            listPlate = ConvertClass.ConvertTo<Maticsoft.Model.PlateOfTheMsg>(plateOfTheMsgBLL.GetAllList().Tables[0]);
            lblNews.Text = listPlate.Where(p => p.plateId == "lblNews").FirstOrDefault().PlateName;
            lblConsulting.Text = listPlate.Where(p => p.plateId == "lblConsulting").FirstOrDefault().PlateName;
            lblCunGuan.Text = listPlate.Where(p => p.plateId == "lblCunGuan").FirstOrDefault().PlateName;
            lblGongYi.Text = listPlate.Where(p => p.plateId == "lblGongYi").FirstOrDefault().PlateName;
            lblPinKun.Text = listPlate.Where(p => p.plateId == "lblPinKun").FirstOrDefault().PlateName;
            lblPolicy.Text = listPlate.Where(p => p.plateId == "lblPolicy").FirstOrDefault().PlateName;
            lblQiYe.Text = listPlate.Where(p => p.plateId == "lblQiYe").FirstOrDefault().PlateName;
            lblShiFan.Text = listPlate.Where(p => p.plateId == "lblShiFan").FirstOrDefault().PlateName;
            lblYuLu.Text = listPlate.Where(p => p.plateId == "lblYuLu").FirstOrDefault().PlateName;
        }

    }
}